<!--
HTML片段，嵌入弹窗中使用
注：在需要使用id的地方，请取st_jsid参数<?php echo $_GET['st_jsid']; ?>做前缀，避免影响到主页面
-->
<!--添加权限-->
<form action="{%:U('/admin/admin/saveatom')%}" onsubmit="return false" stverify="true" erroappend="true" ajaxpost="true" method="POST">
  <table class="table table-listing">
    <tbody>
    <tr>
      <td class="span4"><span class="text-red">*</span>权限名字：</td>
      <td>
          <input class="input" type="text" name="name" opt="rq" value="{%$atomInfo['name']%}"/>
          <input class="input" type="text" name="id" hidden='true' value="{%$atomInfo['id']%}"/>
      </td>
    </tr>
    <tr>
      <td class="span4"><span class="text-red">*</span>ACTION模块URL地址：</td>
      <td>
        <input class="input" type="text" name="func_name" opt="rq" value="{%$atomInfo['func_name']%}"/>
      </td>
    </tr>    
    <tr>
      <td class="span4">GET参数：</td>
      <td>
        <input class="input" type="text" name="func_data" value="{%$atomInfo['func_data']%}" placeholder="例：act=add&type=show" />
      </td>
    </tr> 
    <tr>
      <td class="span4">是否列表显示：</td>
      <td>
        <select class="st-dropdown" name="hidden_type" data-config="inBox:true">
          <option value="0" {%if condition="$atomInfo['hidden_type'] eq 0"%} selected {%/if%} >隐藏列表</option>
          <option value="1" {%if condition="$atomInfo['hidden_type'] eq 1"%} selected {%/if%} >显示列表</option>
        </select>
      </td>
    </tr>
    <tr>
      <td class="span4">归属大类：</td>
      <td>
          <select class="st-dropdown" name="menuM_id" data-config="inBox:true,subId:'suboption1_<?php echo $_GET['st_jsid']; ?>'">
            <option value="0">所有</option>
           {%notempty name="menuMainList"%}
            {%foreach name="menuMainList" item="vo"%}            
            <option value="{%$vo.class_id%}" 
                 {%if condition="$menuM_id eq $vo['class_id']" %} selected {%/if%}>{%$vo.name%}</option>
            {%/foreach%}
           {%/notempty%}
          </select>
      </td>
    </tr>
    <tr>
      <td class="span4">归属中类：</td>
      <td>
          <select class="st-dropdown" name="menuS_id" id="suboption1_<?php echo $_GET['st_jsid']; ?>"  data-config="inBox:true,subId:'suboption2_<?php echo $_GET['st_jsid']; ?>'">
            <option value="0">所有</option>
           {%notempty name="menuSubList"%}
            {%foreach name="menuSubList" item="vo"%}            
            <option value="{%$vo.class_id%}"
                 {%if condition="$menuS_id eq $vo['class_id']" %} selected {%/if%}>{%$vo.name%}</option>
            {%/foreach%}
           {%/notempty%}
          </select>
      </td>
    </tr>
    <tr>
      <td class="span4">归属小类：</td>
      <td>
          <select class="st-dropdown" name="search_id" id="suboption2_<?php echo $_GET['st_jsid']; ?>" data-config="inBox:true">
            <option value="0">所有</option>
           {%notempty name="searchList"%}
            {%foreach name="searchList" item="vo"%}            
            <option value="{%$vo.class_id%}"
                 {%if condition="$search_id eq $vo['class_id']" %} selected {%/if%}>{%$vo.name%}</option>
            {%/foreach%}
           {%/notempty%}
          </select>
      </td>
    </tr>
    </tbody>
  </table>
</form>